package com.bjsc.mapper;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.baomidou.mybatisplus.plugins.Page;
import com.bjsc.entity.Withdraw;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;
import java.util.Map;

/**
 * @author create by VIC.Huang
 * @date 2018/2/7
 */
@Mapper
public interface WithdrawMapper extends BaseMapper<Withdraw> {
    @Select("select twr.id, twr.user_id userId, tu.nick_name userName, " +
            "   twr.money, twr.qrcode, twr.create_time createTime, twr.handle_status handleStatus" +
            " from t_withdraw_record twr " +
            " left join t_user tu on twr.user_id = tu.id " +
            " order by id desc")
    List<Map<Object,Object>> selectWithdrawList(Page<Map<Object, Object>> page);
}
